home *** CD-ROM | disk | FTP | other *** search
/ Revista do CD-ROM 101 / CD-ROM 101.iso / compl / maya5ple / Install_MayaPLE5_English.exe / Maya / Data1.cab / subdConvertMM.mel < prev    next >
Encoding:
Text File  |  2003-07-17  |  4.1 KB  |  124 lines

  1. // Copyright (C) 1997-2002 Alias|Wavefront,
  2. // a division of Silicon Graphics Limited.
  3. //
  4. // The information in this file is provided for the exclusive use of the
  5. // licensees of Alias|Wavefront.  Such users have the right to use, modify,
  6. // and incorporate this code into other products for purposes authorized
  7. // by the Alias|Wavefront license agreement, without fee.
  8. //
  9. // ALIAS|WAVEFRONT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
  10. // INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
  11. // EVENT SHALL ALIAS|WAVEFRONT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
  12. // CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
  13. // DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  14. // TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  15. // PERFORMANCE OF THIS SOFTWARE.
  16. //
  17. // Copyright (C) 1997-2001 Alias|Wavefront,
  18. // a division of Silicon Graphics Limited.
  19. //
  20. // The information in this file is provided for the exclusive use of the
  21. // licensees of Alias|Wavefront.  Such users have the right to use, modify,
  22. // and incorporate this code into other products for purposes authorized
  23. // by the Alias|Wavefront license agreement, without fee.
  24. //
  25. // ALIAS|WAVEFRONT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
  26. // INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
  27. // EVENT SHALL ALIAS|WAVEFRONT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
  28. // CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
  29. // DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  30. // TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  31. // PERFORMANCE OF THIS SOFTWARE.
  32. //
  33. //  Alias|Wavefront Script File
  34. //  MODIFY THIS AT YOUR OWN RISK
  35. //
  36. //  Creation Date:  11 January 2002
  37. //
  38. //  Procedure Name:
  39. //      subdConvertMM
  40. //
  41. //  Description:
  42. //      This procedure creates the popup/marking menu
  43. //      for subd component conversion. See buildConvertMM.
  44. //
  45. //  Input Arguments:
  46. //      The parent item to parent the popup menu to.
  47. //
  48. //  Return Value:
  49. //      None.
  50.  
  51. global proc subdConvertMM(string $parent){
  52.  
  53.     if (`popupMenu -query -exists $parent`){
  54.         popupMenu -edit -deleteAllItems $parent;
  55.     
  56.         setParent -menu $parent;
  57.         menuItem
  58.             -label "To Edges" 
  59.             -command ("ConvertSelectionToEdges;" +
  60.                 "hilite; selectType -ocm -alc false;" +
  61.                 "selectType -ocm -subdivMeshEdge true;") 
  62.             -radialPosition "N" 
  63.             -annotation (getRunTimeCommandAnnotation ("ConvertSelectionToEdges"))
  64.             ;
  65.  
  66.         menuItem
  67.             -label "Coarser" 
  68.             -command "CoarseLevelComponentDisplay" 
  69.             -radialPosition "NE" 
  70.             -annotation (getRunTimeCommandAnnotation ("CoarseLevelComponentDisplay"))
  71.             ;
  72.  
  73.         menuItem
  74.             -label "To UVs" 
  75.             -command ("ConvertSelectionToUVs;" +
  76.                 "hilite; selectType -ocm -alc false;" +
  77.                 "selectType -ocm -subdivMeshUV true;") 
  78.             -radialPosition "E" 
  79.             -annotation (getRunTimeCommandAnnotation ("ConvertSelectionToUVs"))
  80.             ;
  81.  
  82.         menuItem
  83.             -label "Expand Selection" 
  84.             -command "ExpandSelectedComponents" 
  85.             -radialPosition "SE" 
  86.             -annotation (getRunTimeCommandAnnotation ("ExpandSelectedComponents"))
  87.             ;
  88.  
  89.         menuItem
  90.             -label "To Faces" 
  91.             -command ("ConvertSelectionToFaces;" +
  92.                 "hilite; selectType -ocm -alc false;" +
  93.                 "selectType -ocm -subdivMeshFace true;")
  94.             -radialPosition "S" 
  95.             -annotation (getRunTimeCommandAnnotation ("ConvertSelectionToFaces"))
  96.             ;
  97.  
  98.         menuItem
  99.             -label "Refine Selection" 
  100.             -command "RefineSelectedComponents" 
  101.             -radialPosition "SW" 
  102.             -annotation (getRunTimeCommandAnnotation ("RefineSelectedComponents"))
  103.             ;
  104.  
  105.         menuItem
  106.             -label "To Vertices" 
  107.             -command ("ConvertSelectionToVertices;" +
  108.                 "hilite; selectType -ocm -alc false;" +
  109.                 "selectType -ocm -subdivMeshPoint true;")
  110.             -radialPosition "W" 
  111.             -annotation (getRunTimeCommandAnnotation ("ConvertSelectionToVertices"))
  112.             ;
  113.  
  114.         menuItem
  115.             -label "Finer" 
  116.             -command "FineLevelComponentDisplay" 
  117.             -radialPosition "NW" 
  118.             -annotation (getRunTimeCommandAnnotation ("FineLevelComponentDisplay"))
  119.             ;
  120.  
  121.         setParent -menu ..;
  122.     }
  123. }
  124.